{% extends "main_template.html" %}

{% block content %}
{% if sklists %}
  <table>
    {% for sklist in sklists %}
      <tr>
        <th colspan="3">{{sklist.name}}</th>
      </tr>
      {% for instance in sklist.getInstances %}
        <tr>
          <th colspan="3">{{instance.instance.name}}</th>
        </tr>
      {% endfor %}
      {% for ranks in ranklist %}
      {% for c in ranks %}
        <tr>
          <td class="rank">
           {{c.rank}}
          </td>
          <td style="background-color:#{{c.char.character_class.hex_colour}}">
            <img src="/media/img/{{ c.char.character_class.icon}}" width="16" height="16"/>
          </td>
          <td style="background-color:#{{c.char.character_class.hex_colour}}" class="split">
           <span>{{c.char.name}}
            {% for s in c.suicides %}         
             <img src="/media/img/ring1.png" alt="{{s.item.name}}" title="{{s.item.name}}"/>
            {% endfor %}
           </span>
          </td>
         </tr>
       {% endfor %}
       {% endfor %}
      
    {% endfor %}
  </table>
{% else %}
  <h3>No SK Lists have been created</h3>
{% endif %}
{% endblock %}